{yun:}if !$smarty.cookies.uid{/yun}
<!--当前登录-->
<link rel="stylesheet" href="{yun:}$style{/yun}/style/tck_logoin.css?v={yun:}$config.cachecode{/yun}" type="text/css" />
<div class="none" id="onlogin">
	<!-- 登录弹出框-->
	<div class="login_pop_up_box">
		<div class="login_pop_up_box_right">
	
			
			<div id="login_normal">
				<div class="login_pop_up_box_title">
                <div class="login_pop_up_box_title_b">
					<input type="hidden" name="act" id="act_login" value="0" />
					<ul>
                       <li id="acount_login" class="login_pop_up_cur">账号登录<i class="login_pop_up_curline"></i></li>
                        {yun:}if $config.sy_msg_isopen==1 && $config.sy_msg_login==1{/yun}
						<li id="mobile_login">短信登录<i class="login_pop_up_curline"></i></li>
						{yun:}/if{/yun}
						{yun:}if $config.wx_author=='1'{/yun}
						<li id="code_login" >扫码登录<i class="login_pop_up_curline"></i></li>
                        {yun:}/if{/yun}
					</ul>
				</div></div>
				<!---------------扫码登录页面---------------------->
				<div class="wx_login_show none">
					<div id="wx_login_qrcode" class="wxlogintext">正在获取二维码...</div>
					<div class="wxlogintxt">请使用微信扫一扫登录</div>
                  
				</div>
			<!------------------扫码登录页面end-->
				<div id="login_normal_box">
					<div class="login_pop_up_box_text"><i class="login_pop_up_box_icon login_pop_up_box_icon_zh"></i>
						<input type="text" id="username" placeholder="手机/会员名/邮箱" name="username" class="login_pop_up_box_t" autocomplete="off" />
						<!--提示-->
						<div class="login_pop_up_msg none" id="show_name">
							<div class="login_pop_up_msg_tx">请填写用户名</div>
							<div class="login_pop_up_msg_icon"></div>
						</div>
					</div>
					<div class="login_pop_up_box_text"><i class="login_pop_up_box_icon login_pop_up_box_icon_mm"></i>
						<input type="password" id="password" name="password" placeholder="请输入密码" class="login_pop_up_box_t" autocomplete="off" />
						<div class="login_pop_up_msg none" id="show_pass">
							<div class="login_pop_up_msg_tx">请填写密码</div>
							<div class="login_pop_up_msg_icon"></div>
						</div>
					</div>
				</div>
				<!--    手机动态码登录样式-->
				{yun:}if $config.sy_msg_isopen==1 && $config.sy_msg_login==1{/yun}
				<div class="none" id="login_sj_box">
					<div class="login_pop_up_box_text"><i class="login_pop_up_box_icon login_pop_up_box_icon_sj"></i>
						<input type="text" id="usermoblie" placeholder="请输入手机号码" name="username" class="login_pop_up_box_t" autocomplete="off" />
						<div class="login_pop_up_msg none" id="show_mobile">
							<div class="login_pop_up_msg_tx">请填写正确手机号</div>
							<div class="login_pop_up_msg_icon"></div>
						</div>
					</div>
				</div>
				{yun:}/if{/yun} 
                
				{yun:}if strpos($config.code_web,"前台登录")!==false{/yun} 
				{yun:}if $config.code_kind==3{/yun}

				
				<div class="gtdx-captcha">
					
					
					<input type='hidden' id="geetest_challenge"  name="geetest_challenge" value="">
					<input type='hidden' id="geetest_validate"  name="geetest_validate" value="">
					<input type='hidden' id="geetest_seccode"  name="geetest_seccode" value="">
					<input type='hidden' id="popup-submit">	
					<input type='hidden' id="bind-submit">
				</div>
				{yun:}elseif $config.code_kind==4{/yun}
				
				<div class="gtdx-captcha">
					<input type='hidden' id="dx_token"  name="dx_token" value="">
					<input type='hidden' id="popup-submit">	
					<input type='hidden' id="bind-submit">
				</div>
		
				{yun:}else{/yun}
				<div class="login_pop_up_box_yztext"><i class="login_pop_up_box_icon login_pop_up_box_icon_yz"></i>
					<input id="txt_CheckCode" type="text" maxlength="6" name="authcode" autocomplete="off" placeholder="请输入验证码" class="login_pop_up_box_t">
					<div class="login_pop_up_box_yzimg">
						<img id="vcode_img" src="{yun:}$config.sy_weburl{/yun}/app/include/authcode.inc.php" onclick="checkCode('vcode_img');" style="margin-right:5px; margin-left:5px;cursor:pointer;" />
					</div>
					<div class="login_pop_up_msg none" id="show_code">
						<div class="login_pop_up_msg_tx">请填写验证码</div>
						<div class="login_pop_up_msg_icon"></div>
					</div>
					<input type="hidden" id="login_codekind" value="1" />
				</div>
				{yun:}/if{/yun} 
				{yun:}else{/yun}
				<input type="hidden" id="login_codekind" value="0" /> 
				{yun:}/if{/yun}
				<div class="clear"></div>
				<div class="none" id="login_sjyz_box">
					<div class="login_pop_up_box_sjtext"><i class="login_pop_up_box_icon login_pop_up_box_icon_dx"></i>
						<input id="dynamiccode" type="text" tabindex="3" maxlength="6" name="authcode" autocomplete="off" placeholder="请输入短信验证码" class="login_pop_up_box_t">
						<div class="login_pop_up_msg none" id="show_dynamiccode">
							<div class="login_pop_up_msg_tx">请填写短信动态码</div>
							<div class="login_pop_up_msg_icon"></div>
						</div>
						<a href="javascript:void(0);" class=" login_pop_up_box_yztext_hq" id="send_msg_tip" onclick="send_msg2('{yun:}url m=login c=sendmsg{/yun}');">发送动态码</a>
                        <i class="login_pop_up_box_yztext_line"></i>
					</div>
				</div>
				<input type="hidden" id="login_usertype" />
				<input id="sublogin" class="login_pop_up_box_bth" type="button" onclick="check_login('{yun:}url m=login c=loginsave{/yun}','vcode_img',1);" value="登 录">
				
				<div class="login_pop_up_box_fot">
                	没有账号？<a href="###" id="onregister" target="_blank">立即注册</a>
					<a href="{yun:}url m=forgetpw{/yun}" class="login_pop_up_box_rightreg">忘记密码？</a>
					
				</div>
                 {yun:}if $config.sy_qqlogin==1 || $config.sy_sinalogin==1 || $config.wx_author==1{/yun}
                
				<div class="login_pop_up_box_other"><div class="login_pop_up_box_othertit"><span class="login_pop_up_box_othertit_n">其他方式登录</span></div>
					{yun:}if $config.wx_author==1{/yun}
					<a href="{yun:}url m=wxconnect{/yun}" class="login_pop_up_box_other_wx"></a>
					{yun:}/if{/yun}
					{yun:}if $config.sy_qqlogin==1{/yun}
					<a href="{yun:}$config.sy_weburl{/yun}/qqlogin.php" class="login_pop_up_box_other_qq"></a>
					{yun:}/if{/yun}
					{yun:}if $config.sy_sinalogin==1{/yun}
					<a href="{yun:}url m=sinaconnect{/yun}" class="login_pop_up_box_other_sina"></a>
					{yun:}/if{/yun} 
				</div>
                   {yun:}/if{/yun}
			</div>
		</div>
	</div>
</div>
<div id="bind-captcha" data-id='sublogin' data-type='click'></div>
{yun:}if $config.code_kind == 3{/yun}
<script src="{yun:}$config.sy_weburl{/yun}/js/geetest/gt.js?v={yun:}$config.cachecode{/yun}"></script>
<script src="{yun:}$config.sy_weburl{/yun}/js/geetest/pc.js?v={yun:}$config.cachecode{/yun}" type="text/javascript"></script>
{yun:}elseif $config.code_kind == 4{/yun}
<script src="https://cdn.dingxiang-inc.com/ctu-group/captcha-ui/index.js"></script>
<script>var dxappid = "{yun:}$config.sy_dxappid{/yun}";</script>
<script src="{yun:}$config.sy_weburl{/yun}/js/dingxiang/pc.js?v={yun:}$config.cachecode{/yun}" type="text/javascript"></script>
{yun:}/if{/yun}
<script src="{yun:}$style{/yun}/js/reg_ajax.js?v={yun:}$config.cachecode{/yun}" type="text/javascript"></script>
<script>
	var code_kind = '{yun:}$config.code_kind{/yun}';
	function showlogin(usertype) {
		checkCode('vcode_img');
		$("#login_usertype").val(usertype);
   
		var reg_moblie = '{yun:}$config.reg_moblie{/yun}';
		var reg_email = '{yun:}$config.reg_email{/yun}';
		$("#onregister").attr("href", '{yun:}url m=register{/yun}');
		$('#bind-captcha').attr('data-id','sublogin');
		$("#bind-captcha").attr('data-type','click');
		
		$.layer({
			id: 'onloginid',
			type: 1,
			title: '欢迎登录',
			closeBtn: [0, true],
			offset: ['20%'],
			border: [10, 0.3, '#000', true],
			area: ['410px', 'auto'],
			zIndex:100,
			page: {
				dom: "#onlogin"
			}
		});
	}
	$(document).ready(function() {

		
		var setval;

		//账号登录和手机登录tab选择
		$('#acount_login').click(function(data) {
			$('#acount_login').removeClass().addClass('login_pop_up_cur');
			$('#mobile_login').removeClass();
			$('#code_login').removeClass();
			$('#login_normal_box').show();
			$('#sublogin').show();
			$('#login_sj_box').hide();
			$('.logoin_tck_t_list').show();
			$('.login_pop_up_box_yztext').show();
			$('.login_pop_up_box_fot').show();
			$('.login_pop_up_box_other').show();
			$('#login_sjyz_box').hide();
			$('.wx_login_show').hide();
			$('#act_login').val('0');
			$('#bind-captcha').attr('data-id','sublogin');
		});
		$('#mobile_login').click(function(data) {
			$('#mobile_login').removeClass().addClass('login_pop_up_cur');
			$('#acount_login').removeClass();
			$('#code_login').removeClass();
			$('#login_sj_box').show();
			$('.logoin_tck_t_list').show();
			$('.login_pop_up_box_yztext').show();
			$('#login_sjyz_box').show();
			$('#sublogin').show();
			$('#login_normal_box').hide();
			$('.wx_login_show').hide();
			$('.login_pop_up_box_fot').show();
			$('.login_pop_up_box_other').show();
			$('#act_login').val('1');
			
			$('#bind-captcha').attr('data-id','send_msg_tip');
		});
		$('#code_login').click(function(data) {
			$('#code_login').removeClass().addClass('login_pop_up_cur');
			$('#acount_login').removeClass();
			$('#mobile_login').removeClass();
			$('#login_sj_box').hide();
			$('.logoin_tck_t_list').hide();
			$('.login_pop_up_box_yztext').hide();
			$('.login_pop_up_box_fot').hide();
			$('.login_pop_up_box_other').hide();
			$('#login_sjyz_box').hide();
			$('#login_normal_box').hide();
			$('#sublogin').hide();
			$('.wx_login_show').show();
			
			$.post('{yun:}url m=login c=wxlogin{/yun}', {
				t: 1
			}, function(data) {
				if(data == 0) {
					$('#wx_login_qrcode').html('二维码获取失败..');
				} else {
					$('#wx_login_qrcode').html('<img src="' + data + '" width="100" height="100">');
					setval = setInterval(function(){
						$.post('{yun:}url m=login c=getwxloginstatus{/yun}', {
							t: 1
						}, function(data) {
							var data = eval('(' + data + ')');
							if(data.url != '' && data.msg != '') {
								clearInterval(setval);
								layer.msg(data.msg, 2, 9, function() {
									window.location.href = data.url;
								});
							} else if(data.url) {
								clearInterval(setval);
								window.location.href = '';
							}
						});
					}, 2000);
				}
			});
		});
	});

	
</script>
{yun:}/if{/yun}